<template>
  <div class="app-container">
    <el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px">
      <el-form-item label="记录编号" prop="jilbh">
        <el-input v-model="queryParams.jilbh" placeholder="请输入记录编号" clearable @keyup.enter.native="handleQuery" />
      </el-form-item>
      <el-form-item label="样品名称" prop="yangpmc">
        <el-input v-model="queryParams.yangpmc" placeholder="请输入样品名称" clearable @keyup.enter.native="handleQuery" />
      </el-form-item>
      <el-form-item label="样品编号" prop="yangpbh">
        <el-input v-model="queryParams.yangpbh" placeholder="请输入样品编号" clearable @keyup.enter.native="handleQuery" />
      </el-form-item>
      <el-form-item>
        <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
        <el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>
      </el-form-item>
    </el-form>

    <el-row :gutter="10" class="mb5 top-right-btn small-line-height">
      <el-col :span="1.5">
        <el-button type="primary" plain icon="el-icon-plus" size="mini" @click="handleAdd" v-hasPermi="['report_tg:tgTdhslbBsInfo:add']">新增</el-button>
      </el-col>
      <el-col :span="1.5">
        <el-button type="success" plain icon="el-icon-edit" size="mini" :disabled="single" @click="handleUpdate" v-hasPermi="['report_tg:tgTdhslbBsInfo:edit']">修改</el-button>
      </el-col>
      <el-col :span="1.5">
        <el-button type="danger" plain icon="el-icon-delete" size="mini" :disabled="multiple" @click="handleDelete" v-hasPermi="['report_tg:tgTdhslbBsInfo:remove']">删除</el-button>
      </el-col>
      <el-col :span="1.5">
        <el-button type="warning" plain icon="el-icon-download" size="mini" @click="handleExport" v-hasPermi="['report_tg:tgTdhslbBsInfo:export']">导出</el-button>
      </el-col>
      <!-- <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar> -->
    </el-row>

    <el-table border stripe v-loading="loading" :data="tgTdhslbBsInfoList" @selection-change="handleSelectionChange">
      <el-table-column type="selection" width="55" align="center" />
      <el-table-column label="主键" align="center" prop="excelId" v-if="true" />
      <el-table-column label="共几页" align="center" prop="totalPage" />
      <el-table-column label="第几页" align="center" prop="page" />
      <el-table-column label="记录编号" align="center" prop="jilbh" />
      <el-table-column label="检测单位名称" align="center" prop="jiancdwmc" />
      <el-table-column label="工程部位/用途" align="center" prop="gongcbwyt" />
      <el-table-column label="样品名称" align="center" prop="yangpmc" />
      <el-table-column label="样品编号" align="center" prop="yangpbh" />
      <el-table-column label="样品数量" align="center" prop="yangpsl" />
      <el-table-column label="样品状态" align="center" prop="yangpzt" />
      <el-table-column label="样品时间" align="center" prop="yangpsj" width="180">
        <template slot-scope="scope">
          <span>{{ parseTime(scope.row.yangpsj, '{y}-{m}-{d}') }}</span>
        </template>
      </el-table-column>
      <el-table-column label="试验检测日期" align="center" prop="shiyjcrq" />
      <el-table-column label="试验条件温度" align="center" prop="shiytjwd" />
      <el-table-column label="试验条件湿度" align="center" prop="shiytjsd" />
      <el-table-column label="检测依据" align="center" prop="jiancyj" />
      <el-table-column label="判定依据" align="center" prop="pandyj" />
      <el-table-column label="主要仪器设备名称及编号" align="center" prop="zhuyyqsbmcjbh" />
      <el-table-column label="盒号11" align="center" prop="heh11" />
      <el-table-column label="盒质量11" align="center" prop="hezl11" />
      <el-table-column label="盒+湿土质量11" align="center" prop="hejstzl11" />
      <el-table-column label="盒+干土质量11" align="center" prop="hejgtzl11" />
      <el-table-column label="水分质量11" align="center" prop="shuifzl11" />
      <el-table-column label="干土质量11" align="center" prop="gantzl11" />
      <el-table-column label="含水率11" align="center" prop="hansl11" />
      <el-table-column label="盒号12" align="center" prop="heh12" />
      <el-table-column label="盒质量12" align="center" prop="hezl12" />
      <el-table-column label="盒+湿土质量12" align="center" prop="hejstzl12" />
      <el-table-column label="盒+干土质量12" align="center" prop="hejgtzl12" />
      <el-table-column label="水分质量12" align="center" prop="shuifzl12" />
      <el-table-column label="干土质量12" align="center" prop="gantzl12" />
      <el-table-column label="含水率12" align="center" prop="hansl12" />
      <el-table-column label="含水率平均值1" align="center" prop="hanslpjz1" />
      <el-table-column label="盒号21" align="center" prop="heh21" />
      <el-table-column label="盒质量21" align="center" prop="hezl21" />
      <el-table-column label="盒+湿土质量21" align="center" prop="hejstzl21" />
      <el-table-column label="盒+干土质量21" align="center" prop="hejgtzl21" />
      <el-table-column label="水分质量21" align="center" prop="shuifzl21" />
      <el-table-column label="干土质量21" align="center" prop="gantzl21" />
      <el-table-column label="含水率21" align="center" prop="hansl21" />
      <el-table-column label="盒号22" align="center" prop="heh22" />
      <el-table-column label="盒质量22" align="center" prop="hezl22" />
      <el-table-column label="盒+湿土质量22" align="center" prop="hejstzl22" />
      <el-table-column label="盒+干土质量22" align="center" prop="hejgtzl22" />
      <el-table-column label="水分质量22" align="center" prop="shuifzl22" />
      <el-table-column label="干土质量22" align="center" prop="gantzl22" />
      <el-table-column label="含水率22" align="center" prop="hansl22" />
      <el-table-column label="含水率平均值2" align="center" prop="hanslpjz2" />
      <el-table-column label="盒号31" align="center" prop="heh31" />
      <el-table-column label="盒质量31" align="center" prop="hezl31" />
      <el-table-column label="盒+湿土质量31" align="center" prop="hejstzl31" />
      <el-table-column label="盒+干土质量31" align="center" prop="hejgtzl31" />
      <el-table-column label="水分质量31" align="center" prop="shuifzl31" />
      <el-table-column label="干土质量31" align="center" prop="gantzl31" />
      <el-table-column label="含水率31" align="center" prop="hansl31" />
      <el-table-column label="盒号32" align="center" prop="heh32" />
      <el-table-column label="盒质量32" align="center" prop="hezl32" />
      <el-table-column label="盒+湿土质量32" align="center" prop="hejstzl32" />
      <el-table-column label="盒+干土质量32" align="center" prop="hejgtzl32" />
      <el-table-column label="水分质量32" align="center" prop="shuifzl32" />
      <el-table-column label="干土质量32" align="center" prop="gantzl32" />
      <el-table-column label="含水率32" align="center" prop="hansl32" />
      <el-table-column label="含水率平均值3" align="center" prop="hanslpjz3" />
      <el-table-column label="盒号41" align="center" prop="heh41" />
      <el-table-column label="盒质量41" align="center" prop="hezl41" />
      <el-table-column label="盒+湿土质量41" align="center" prop="hejstzl41" />
      <el-table-column label="盒+干土质量41" align="center" prop="hejgtzl41" />
      <el-table-column label="水分质量41" align="center" prop="shuifzl41" />
      <el-table-column label="干土质量41" align="center" prop="gantzl41" />
      <el-table-column label="含水率41" align="center" prop="hansl41" />
      <el-table-column label="盒号42" align="center" prop="heh42" />
      <el-table-column label="盒质量42" align="center" prop="hezl42" />
      <el-table-column label="盒+湿土质量42" align="center" prop="hejstzl42" />
      <el-table-column label="盒+干土质量42" align="center" prop="hejgtzl42" />
      <el-table-column label="水分质量42" align="center" prop="shuifzl42" />
      <el-table-column label="干土质量42" align="center" prop="gantzl42" />
      <el-table-column label="含水率42" align="center" prop="hansl42" />
      <el-table-column label="含水率平均值4" align="center" prop="hanslpjz4" />
      <el-table-column label="操作" align="center" class-name="small-padding fixed-width">
        <template slot-scope="scope">
          <el-button size="mini" type="text" icon="el-icon-edit" @click="handleUpdate(scope.row)" v-hasPermi="['report_tg:tgTdhslbBsInfo:edit']">修改</el-button>
          <el-button size="mini" type="text" icon="el-icon-delete" @click="handleDelete(scope.row)" v-hasPermi="['report_tg:tgTdhslbBsInfo:remove']">删除</el-button>
        </template>
      </el-table-column>
    </el-table>

    <pagination v-show="total > 0" :total="total" :page.sync="queryParams.pageNum" :limit.sync="queryParams.pageSize" @pagination="getList" />

    <!-- 添加或修改土的含水率记录对话框 -->
    <jy-dialog :title="title" :visible.sync="open" :model="form" :rules="rules" width="1200px" append-to-body>
      <!--      <el-form ref="form" :model="form" :rules="rules" label-width="80px">-->
      <!--      </el-form>-->
      <div class="reportFormPage">
        <div id="domid">
          <el-row>
            <el-col :span="5" :offset="19">
              <div class="pageNumBox">
                第
                <el-input type="text" v-model="form.page" style="border-width:0px;height:100%;width:10%;text-align:left;" />页，共
                <el-input type="text" v-model="form.totalPage" style="border-width:0px;height:100%;width:10%;text-align:left;" />页
              </div>
            </el-col>
          </el-row>
          <div class="topTwoBox">
            <div class="centerName">含水率试验检测记录表(烘干法、酒精燃烧法）</div>
            <div class="codeText">
              <tr>JGLQ01001a</tr>
              <tr>JGLQ01001b</tr>
            </div>
          </div>
          <div class="threeTopBox">
            <div class="threeItem1">检测单位名称：</div>
            <div class="threeItem2">
              <el-input type="text" v-model="form.jiancdwmc" style="border-width:0px;height:100%;width:100%;text-align:left;" />
            </div>
            <div class="threeItem3">
              记录编号：
              <el-input type="text" v-model="form.jilbh" style="border-width:0px;height:100%;width:50%;text-align:left;" />
            </div>
          </div>
          <!-- .........................1111111111111111111111111111111......................................................... -->
          <table border="1" height="110px" bordercolor="#000000" cellpadding="2" cellspacing="0" align="center">
            <tbody>
              <tr>
                <td height="25" align="center" width="15%">
                  <span style="width:90px;display:inline-block">工程名称</span>
                </td>
                <td width="35%" bgcolor="#ffffff">
                  <el-input type="text" v-model="form.gongcmc" style="border-width:0px;height:100%;width:100%;text-align:left;" />
                </td>
                <td align="center" width="15%">
                  <span style="width:90px;display:inline-block">工程部位/用途</span>
                </td>
                <td bgcolor="#ffffff" width="35%">
                  <el-input type="text" v-model="form.gongcbwyt" style="border-width:0px;height:100%;width:100%;text-align:left;" />
                </td>
              </tr>
              <tr>
                <td height="50" align="center">样品信息</td>
                <td style="word-wrap: break-word; word-break :break-all;" colspan="3" bgcolor="#ffffff">
                  样品名称：
                  <el-input type="text" v-model="form.yangpmc" style="border-width:0px;height:100%;width:35%;text-align:left;" />样品编号：
                  <el-input type="text" v-model="form.yangpbh" style="border-width:0px;height:100%;width:40%;text-align:left;" />样品数量：
                  <el-input type="text" v-model="form.yangpsl" style="border-width:0px;height:100%;width:40%;text-align:left;" />样品状态：
                  <el-input type="text" v-model="form.yangpzt" style="border-width:0px;height:100%;width:30%;text-align:left;" />来样时间：
                  <el-input type="text" v-model="form.yangpsj" style="border-width:0px;height:100%;width:40%;text-align:left;" />
                </td>
              </tr>

              <tr>
                <td height="25" align="center" width="15%">
                  <span style="width:90px;display:inline-block">试验检测日期</span>
                </td>
                <td width="35%" bgcolor="#ffffff">
                  <el-input type="text" v-model="form.shiyjcrq" style="border-width:0px;height:100%;width:100%;text-align:left;" />
                </td>
                <td align="center" width="15%">
                  <span style="width:90px;display:inline-block">试验条件</span>
                </td>
                <td bgcolor="#ffffff" width="35%">
                  温度：
                  <el-input type="text" v-model="form.shiytjwd" style="border-width:0px;height:100%;width:15%;text-align:left;" />℃；湿度：
                  <el-input type="text" v-model="form.shiytjsd" style="border-width:0px;height:100%;width:15%;text-align:left;" />%RH
                </td>
              </tr>

              <tr>
                <td height="25" align="center" width="15%">
                  <span style="width:90px;display:inline-block">检测依据</span>
                </td>
                <td width="35%" bgcolor="#ffffff">
                  <el-input type="text" v-model="form.jiancyj" style="border-width:0px;height:100%;width:100%;text-align:left;" />
                </td>
                <td align="center" width="15%">
                  <span style="width:90px;display:inline-block">判定依据</span>
                </td>
                <td bgcolor="#ffffff" width="35%">
                  <el-input type="text" v-model="form.pandyj" style="border-width:0px;height:100%;width:100%;text-align:left;" />
                </td>
              </tr>

              <tr>
                <td height="30" align="center">
                  主要仪器设备
                  <br />名称及编号
                </td>
                <td colspan="3" bgcolor="#ffffff">
                  <el-input type="text" v-model="form.zhuyyqsbmcjbh" style="border-width:0px;height:100%;width:100%;text-align:left;" />
                </td>
              </tr>
            </tbody>
          </table>
          <!-- .................................22222222222222222222222222222222............................................... -->
          <table cellpadding="1" cellspacing="0" bordercolor="#000000" style="border-right: 2px solid black; border-top: none; border-left: 2px solid black; border-bottom: 2px solid black; border-collapse: collapse;  height: 616px; text-align: center;" align="center" border="1" tbindex="0">
            <tbody>
              <tr trindex="0">
                <td width="20%" colspan="2" rowspan="1">试验次数</td>
                <td width="20%" colspan="2">1</td>
                <td width="20%" colspan="2">2</td>
                <td width="20%" colspan="2">3</td>
                <td width="20%" colspan="2">4</td>
              </tr>
              <tr trindex="1">
                <td colspan="2" rowspan="1">盒号</td>
                <td colspan="1">
                  <el-input type="text" style="width: 100%; text-align: center" tabindex="200" size="2" v-model="form.heh11" />
                </td>
                <td colspan="1">
                  <el-input type="text" style="width: 100%; text-align: center" tabindex="200" size="2" v-model="form.heh12" />
                </td>
                <td colspan="1">
                  <el-input type="text" style="width: 100%; text-align: center" tabindex="200" size="2" v-model="form.heh21" />
                </td>
                <td colspan="1">
                  <el-input type="text" style="width: 100%; text-align: center" tabindex="200" size="2" v-model="form.heh22" />
                </td>
                <td colspan="1">
                  <el-input type="text" style="width: 100%; text-align: center" tabindex="200" size="2" v-model="form.heh31" />
                </td>
                <td colspan="1">
                  <el-input type="text" style="width: 100%; text-align: center" tabindex="200" size="2" v-model="form.heh32" />
                </td>
                <td colspan="1">
                  <el-input type="text" style="width: 100%; text-align: center" tabindex="200" size="2" v-model="form.heh41" />
                </td>
                <td colspan="1">
                  <el-input type="text" style="width: 100%; text-align: center" tabindex="200" size="2" v-model="form.heh42" />
                </td>
              </tr>
              <tr trindex="2">
                <td colspan="2" rowspan="1">盒质量(g)</td>
                <td colspan="1">
                  <el-input type="text" style="width: 100%; text-align: center" tabindex="200" size="2" v-model="form.hezl11" />
                </td>
                <td colspan="1">
                  <el-input type="text" style="width: 100%; text-align: center" tabindex="200" size="2" v-model="form.hezl12" />
                </td>
                <td colspan="1">
                  <el-input type="text" style="width: 100%; text-align: center" tabindex="200" size="2" v-model="form.hezl21" />
                </td>
                <td colspan="1">
                  <el-input type="text" style="width: 100%; text-align: center" tabindex="200" size="2" v-model="form.hezl22" />
                </td>
                <td colspan="1">
                  <el-input type="text" style="width: 100%; text-align: center" tabindex="200" size="2" v-model="form.hezl31" />
                </td>
                <td colspan="1">
                  <el-input type="text" style="width: 100%; text-align: center" tabindex="200" size="2" v-model="form.hezl32" />
                </td>
                <td colspan="1">
                  <el-input type="text" style="width: 100%; text-align: center" tabindex="200" size="2" v-model="form.hezl41" />
                </td>
                <td colspan="1">
                  <el-input type="text" style="width: 100%; text-align: center" tabindex="200" size="2" v-model="form.hezl42" />
                </td>
              </tr>
              <tr trindex="3">
                <td colspan="2" rowspan="1">盒+湿土质量(g)</td>
                <td colspan="1">
                  <el-input type="text" style="width: 100%; text-align: center" tabindex="200" size="2" v-model="form.hejstzl11" />
                </td>
                <td colspan="1">
                  <el-input type="text" style="width: 100%; text-align: center" tabindex="200" size="2" v-model="form.hejstzl12" />
                </td>
                <td colspan="1">
                  <el-input type="text" style="width: 100%; text-align: center" tabindex="200" size="2" v-model="form.hejstzl21" />
                </td>
                <td colspan="1">
                  <el-input type="text" style="width: 100%; text-align: center" tabindex="200" size="2" v-model="form.hejstzl22" />
                </td>
                <td colspan="1">
                  <el-input type="text" style="width: 100%; text-align: center" tabindex="200" size="2" v-model="form.hejstzl31" />
                </td>
                <td colspan="1">
                  <el-input type="text" style="width: 100%; text-align: center" tabindex="200" size="2" v-model="form.hejstzl32" />
                </td>
                <td colspan="1">
                  <el-input type="text" style="width: 100%; text-align: center" tabindex="200" size="2" v-model="form.hejstzl41" />
                </td>
                <td colspan="1">
                  <el-input type="text" style="width: 100%; text-align: center" tabindex="200" size="2" v-model="form.hejstzl42" />
                </td>
              </tr>
              <tr trindex="4">
                <td colspan="2" rowspan="1">盒+干土质量(g)</td>
                <td colspan="1">
                  <el-input type="text" style="width: 100%; text-align: center" tabindex="200" size="2" v-model="form.hejgtzl11" />
                </td>
                <td colspan="1">
                  <el-input type="text" style="width: 100%; text-align: center" tabindex="200" size="2" v-model="form.hejgtzl12" />
                </td>
                <td colspan="1">
                  <el-input type="text" style="width: 100%; text-align: center" tabindex="200" size="2" v-model="form.hejgtzl21" />
                </td>
                <td colspan="1">
                  <el-input type="text" style="width: 100%; text-align: center" tabindex="200" size="2" v-model="form.hejgtzl22" />
                </td>
                <td colspan="1">
                  <el-input type="text" style="width: 100%; text-align: center" tabindex="200" size="2" v-model="form.hejgtzl31" />
                </td>
                <td colspan="1">
                  <el-input type="text" style="width: 100%; text-align: center" tabindex="200" size="2" v-model="form.hejgtzl32" />
                </td>
                <td colspan="1">
                  <el-input type="text" style="width: 100%; text-align: center" tabindex="200" size="2" v-model="form.hejgtzl41" />
                </td>
                <td colspan="1">
                  <el-input type="text" style="width: 100%; text-align: center" tabindex="200" size="2" v-model="form.hejgtzl42" />
                </td>
              </tr>
              <tr trindex="5">
                <td colspan="2" rowspan="1">水分质量(g)</td>
                <td colspan="1">
                  <el-input type="text" style="width: 100%; text-align: center" tabindex="200" size="2" v-model="form.shuifzl11" />
                </td>
                <td colspan="1">
                  <el-input type="text" style="width: 100%; text-align: center" tabindex="200" size="2" v-model="form.shuifzl12" />
                </td>
                <td colspan="1">
                  <el-input type="text" style="width: 100%; text-align: center" tabindex="200" size="2" v-model="form.shuifzl21" />
                </td>
                <td colspan="1">
                  <el-input type="text" style="width: 100%; text-align: center" tabindex="200" size="2" v-model="form.shuifzl22" />
                </td>
                <td colspan="1">
                  <el-input type="text" style="width: 100%; text-align: center" tabindex="200" size="2" v-model="form.shuifzl31" />
                </td>
                <td colspan="1">
                  <el-input type="text" style="width: 100%; text-align: center" tabindex="200" size="2" v-model="form.shuifzl32" />
                </td>
                <td colspan="1">
                  <el-input type="text" style="width: 100%; text-align: center" tabindex="200" size="2" v-model="form.shuifzl41" />
                </td>
                <td colspan="1">
                  <el-input type="text" style="width: 100%; text-align: center" tabindex="200" size="2" v-model="form.shuifzl42" />
                </td>
              </tr>
              <tr trindex="6">
                <td colspan="2" rowspan="1">干土质量(g)</td>
                <td colspan="1">
                  <el-input type="text" style="width: 100%; text-align: center" tabindex="200" size="2" v-model="form.gantzl11" />
                </td>
                <td colspan="1">
                  <el-input type="text" style="width: 100%; text-align: center" tabindex="200" size="2" v-model="form.gantzl12" />
                </td>
                <td colspan="1">
                  <el-input type="text" style="width: 100%; text-align: center" tabindex="200" size="2" v-model="form.gantzl21" />
                </td>
                <td colspan="1">
                  <el-input type="text" style="width: 100%; text-align: center" tabindex="200" size="2" v-model="form.gantzl22" />
                </td>
                <td colspan="1">
                  <el-input type="text" style="width: 100%; text-align: center" tabindex="200" size="2" v-model="form.gantzl31" />
                </td>
                <td colspan="1">
                  <el-input type="text" style="width: 100%; text-align: center" tabindex="200" size="2" v-model="form.gantzl32" />
                </td>
                <td colspan="1">
                  <el-input type="text" style="width: 100%; text-align: center" tabindex="200" size="2" v-model="form.gantzl41" />
                </td>
                <td colspan="1">
                  <el-input type="text" style="width: 100%; text-align: center" tabindex="200" size="2" v-model="form.gantzl42" />
                </td>
              </tr>
              <tr trindex="7">
                <td colspan="2" rowspan="1">含水率(%)</td>
                <td colspan="1">
                  <el-input type="text" style="width: 100%; text-align: center" tabindex="200" size="2" v-model="form.hansl11" />
                </td>
                <td colspan="1">
                  <el-input type="text" style="width: 100%; text-align: center" tabindex="200" size="2" v-model="form.hansl12" />
                </td>
                <td colspan="1">
                  <el-input type="text" style="width: 100%; text-align: center" tabindex="200" size="2" v-model="form.hansl21" />
                </td>
                <td colspan="1">
                  <el-input type="text" style="width: 100%; text-align: center" tabindex="200" size="2" v-model="form.hansl22" />
                </td>
                <td colspan="1">
                  <el-input type="text" style="width: 100%; text-align: center" tabindex="200" size="2" v-model="form.hansl31" />
                </td>
                <td colspan="1">
                  <el-input type="text" style="width: 100%; text-align: center" tabindex="200" size="2" v-model="form.hansl32" />
                </td>
                <td colspan="1">
                  <el-input type="text" style="width: 100%; text-align: center" tabindex="200" size="2" v-model="form.hansl41" />
                </td>
                <td colspan="1">
                  <el-input type="text" style="width: 100%; text-align: center" tabindex="200" size="2" v-model="form.hansl42" />
                </td>
              </tr>
              <tr trindex="8">
                <td colspan="2" rowspan="1">含水率平均值(%)</td>
                <td colspan="2">
                  <el-input type="text" style="width: 100%; text-align: center" tabindex="200" size="2" v-model="form.hanslpjz1" />
                </td>
                <td colspan="2">
                  <el-input type="text" style="width: 100%; text-align: center" tabindex="200" size="2" v-model="form.hanslpjz2" />
                </td>
                <td colspan="2">
                  <el-input type="text" style="width: 100%; text-align: center" tabindex="200" size="2" v-model="form.hanslpjz3" />
                </td>
                <td colspan="2">
                  <el-input type="text" style="width: 100%; text-align: center" tabindex="200" size="2" v-model="form.hanslpjz4" />
                </td>
              </tr>
            </tbody>
          </table>
          <!-- .....................................................33333333333333333................................................... -->
          <table cellpadding="2" cellspacing="0" bordercolor="#000000" style="width: 100%; border-right:  2px solid black;  border-left: 2px solid black; border-top-style: none;  border-bottom: 2px solid black; border-collapse: collapse; margin: none;">
            <tbody>
              <tr>
                <td height="30" align="center">附加声明：</td>
                <td colspan="3" bgcolor="#ffffff">
                  <el-input type="text" v-model="form.fujsm" style="border-width:0px;height:100%;width:100%;text-align:left;" />
                </td>
              </tr>
            </tbody>
          </table>
          <!-- .................................44444444444............................................. -->
          <table border="0" cellpadding="0" cellspacing="0" align="center" style="width: 100%; border-collapse:collapse;height:22px;">
            <tbody>
              <tr>
                <td width="10%" align="right">检测：</td>
                <td width="15%" align="left"></td>
                <td width="10%" align="right">审核：</td>
                <td width="15%" align="left"></td>
                <td width="10%" align="right">批准：</td>
                <td align="left" width="15%"></td>
                <td width="10%">日期：</td>
                <td align="left" width="15%"></td>
              </tr>
            </tbody>
          </table>
        </div>
      </div>
      <div slot="footer" class="dialog-footer">
        <el-button size="small" :loading="buttonLoading" type="primary" @click="submitForm">确 定</el-button>
        <el-button size="small" @click="cancel">取 消</el-button>
      </div>
    </jy-dialog>
  </div>
</template>

<script>
import { listTgTdhslbBsInfo, getTgTdhslbBsInfo, delTgTdhslbBsInfo, addTgTdhslbBsInfo, updateTgTdhslbBsInfo } from "@/api/report_tg/tgTdhslbBsInfo";

export default {
  name: "TgTdhslbBsInfo",
  data() {
    return {
      // 按钮loading
      buttonLoading: false,
      // 遮罩层
      loading: true,
      // 选中数组
      ids: [],
      // 非单个禁用
      single: true,
      // 非多个禁用
      multiple: true,
      // 显示搜索条件
      showSearch: true,
      // 总条数
      total: 0,
      // 土的含水率记录表格数据
      tgTdhslbBsInfoList: [],
      // 弹出层标题
      title: "",
      // 是否显示弹出层
      open: false,
      // 查询参数
      queryParams: {
        pageNum: 1,
        pageSize: 10,
        jilbh: undefined,
        yangpmc: undefined,
        yangpbh: undefined
      },
      // 表单参数
      form: {},
      // 表单校验
      rules: {
        excelId: [{ required: true, message: "主键不能为空", trigger: "blur" }]
      }
    };
  },
  created() {
    this.getList();
  },
  methods: {
    /** 查询土的含水率记录列表 */
    getList() {
      this.loading = true;
      listTgTdhslbBsInfo(this.queryParams).then((response) => {
        this.tgTdhslbBsInfoList = response.rows;
        this.total = response.total;
        this.loading = false;
      });
    },
    // 取消按钮
    cancel() {
      this.open = false;
      this.reset();
    },
    // 表单重置
    reset() {
      this.form = {
        excelId: undefined,
        totalPage: undefined,
        page: undefined,
        jilbh: undefined,
        jiancdwmc: undefined,
        gongcbwyt: undefined,
        yangpmc: undefined,
        yangpbh: undefined,
        yangpsl: undefined,
        yangpzt: undefined,
        yangpsj: undefined,
        shiyjcrq: undefined,
        shiytjwd: undefined,
        shiytjsd: undefined,
        jiancyj: undefined,
        pandyj: undefined,
        zhuyyqsbmcjbh: undefined,
        createBy: undefined,
        delFlag: undefined,
        createTime: undefined,
        updateBy: undefined,
        updateTime: undefined,
        heh11: undefined,
        hezl11: undefined,
        hejstzl11: undefined,
        hejgtzl11: undefined,
        shuifzl11: undefined,
        gantzl11: undefined,
        hansl11: undefined,
        heh12: undefined,
        hezl12: undefined,
        hejstzl12: undefined,
        hejgtzl12: undefined,
        shuifzl12: undefined,
        gantzl12: undefined,
        hansl12: undefined,
        hanslpjz1: undefined,
        heh21: undefined,
        hezl21: undefined,
        hejstzl21: undefined,
        hejgtzl21: undefined,
        shuifzl21: undefined,
        gantzl21: undefined,
        hansl21: undefined,
        heh22: undefined,
        hezl22: undefined,
        hejstzl22: undefined,
        hejgtzl22: undefined,
        shuifzl22: undefined,
        gantzl22: undefined,
        hansl22: undefined,
        hanslpjz2: undefined,
        heh31: undefined,
        hezl31: undefined,
        hejstzl31: undefined,
        hejgtzl31: undefined,
        shuifzl31: undefined,
        gantzl31: undefined,
        hansl31: undefined,
        heh32: undefined,
        hezl32: undefined,
        hejstzl32: undefined,
        hejgtzl32: undefined,
        shuifzl32: undefined,
        gantzl32: undefined,
        hansl32: undefined,
        hanslpjz3: undefined,
        heh41: undefined,
        hezl41: undefined,
        hejstzl41: undefined,
        hejgtzl41: undefined,
        shuifzl41: undefined,
        gantzl41: undefined,
        hansl41: undefined,
        heh42: undefined,
        hezl42: undefined,
        hejstzl42: undefined,
        hejgtzl42: undefined,
        shuifzl42: undefined,
        gantzl42: undefined,
        hansl42: undefined,
        hanslpjz4: undefined
      };
      this.resetForm("form");
    },
    /** 搜索按钮操作 */
    handleQuery() {
      this.queryParams.pageNum = 1;
      this.getList();
    },
    /** 重置按钮操作 */
    resetQuery() {
      this.resetForm("queryForm");
      this.handleQuery();
    },
    // 多选框选中数据
    handleSelectionChange(selection) {
      this.ids = selection.map((item) => item.excelId);
      this.single = selection.length !== 1;
      this.multiple = !selection.length;
    },
    /** 新增按钮操作 */
    handleAdd() {
      this.reset();
      this.open = true;
      this.title = "添加土的含水率记录";
    },
    /** 修改按钮操作 */
    handleUpdate(row) {
      this.loading = true;
      this.reset();
      const excelId = row.excelId || this.ids;
      getTgTdhslbBsInfo(excelId).then((response) => {
        this.loading = false;
        this.form = response.data;
        this.open = true;
        this.title = "修改土的含水率记录";
      });
    },
    /** 提交按钮 */
    submitForm() {
      // this.$refs["form"].validate(valid => {
      //   if (valid) {
      this.buttonLoading = true;
      if (this.form.excelId != null) {
        updateTgTdhslbBsInfo(this.form)
          .then((response) => {
            this.$modal.msgSuccess("修改成功");
            this.open = false;
            this.getList();
          })
          .finally(() => {
            this.buttonLoading = false;
          });
      } else {
        addTgTdhslbBsInfo(this.form)
          .then((response) => {
            this.$modal.msgSuccess("新增成功");
            this.open = false;
            this.getList();
          })
          .finally(() => {
            this.buttonLoading = false;
          });
      }
      // }
      // });
    },
    /** 删除按钮操作 */
    handleDelete(row) {
      const excelIds = row.excelId || this.ids;
      this.$modal
        .confirm('是否确认删除土的含水率记录编号为"' + excelIds + '"的数据项？')
        .then(() => {
          this.loading = true;
          return delTgTdhslbBsInfo(excelIds);
        })
        .then(() => {
          this.loading = false;
          this.getList();
          this.$modal.msgSuccess("删除成功");
        })
        .catch(() => {})
        .finally(() => {
          this.loading = false;
        });
    },
    /** 导出按钮操作 */
    handleExport() {
      this.download(
        "report_tg/tgTdhslbBsInfo/export",
        {
          ...this.queryParams
        },
        `tgTdhslbBsInfo_${new Date().getTime()}.xlsx`
      );
    }
  }
};
</script>

<style scoped lang="scss">
  @import url("~@/views/reportForms/style/reportForm.scss");
</style>
